Skip to content

Conversation

CitralFlo
Copy link
Member

@CitralFlo CitralFlo commented Aug 30, 2025

Methods do not change so #1136 can be merged :>

@CitralFlo CitralFlo requested a review from a team as a code owner August 30, 2025 20:27
@CitralFlo CitralFlo changed the title User Manager uses repository now! GH-1147 User Manager uses repository now! Aug 30, 2025
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the UserManager to use a repository pattern for data persistence, which is a great improvement. I've identified a few issues, including a critical bug that causes double database writes and a race condition during initial data loading. Additionally, there are opportunities to improve code clarity and maintainability by simplifying some logic and improving API design. The new integration tests are a good addition, but could be improved by removing console output.

@CitralFlo CitralFlo requested a review from sadcenter September 1, 2025 19:59
@CitralFlo CitralFlo marked this pull request as draft September 1, 2025 21:29
Copy link

@sadcenter sadcenter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM


@Override
public CompletableFuture<Collection<User>> fetchUsersBatch(int batchSize) {
return CompletableFuture.supplyAsync(() -> {
Copy link

@sadcenter sadcenter Sep 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you should supply a custom executor, since you are already using one in all AbstractRepositoryOrmLite methods

@Jakubk15 Jakubk15 changed the title GH-1147 User Manager uses repository now! GH-1147 Make UserManager use UserRepository Sep 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants